<template>
<div>
{{nameee}} <br>
  {{tnameee}}登录成功
  <template>
    <el-table
        :data="table"
        border
        style="width: 100%">
      <el-table-column
          prop="id"
          label="编号"
          width="180">
      </el-table-column>
      <el-table-column
          prop="name"
          label="用户名"
          width="180">
      </el-table-column>
      <el-table-column
          prop="tname"
          label="姓名">
      </el-table-column>
    </el-table>
  </template>

</div>
</template>

<script>
export default {
  name: "UserView",
  data() {
    return {
      table:[],
      nameee:sessionStorage.getItem("nameee"),
      tnameee:sessionStorage.getItem("tnameee"),

    }
  }, methods: {
    list(){
      this.axios.get("user/list").then(res=>{
          this.table=res.data.data;
      })
    }

  }, created() {
    this.list();
  }
}
</script>

<style scoped>

</style>